package com.ct.goods.responsity.admin;

import com.ct.goods.mapper.GoodsFavImportMapper;
import com.ct.goods.orm.GoodsFavImport;
import com.ct.repository.commons.BaseServiceImpl;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class AdminGoodsFavImportRepository extends BaseServiceImpl<GoodsFavImportMapper, GoodsFavImport> implements IAdminGoodsFavImportRepository {

    /**
     * 查询我的收藏商品
     */
    public List<GoodsFavImport> getFavGoodsByUserId(List<Long> userId) {
        return this.lambdaQuery()
                .in(GoodsFavImport::getUserId, userId)
                .list();
    }
}
